In related U.S. patent application Ser. No. 10/924,652 and U.S. patent application Ser. No. 10/668,833, a time-dependent data storage and recovery technique is disclosed. Embodiments of such a technique provide a solution for continuous data protection (CDP) wherein write commands directed to a storage system are intercepted by a storage management system having a current store and a time store. The current store may maintain or have access to a current (or mirror) copy of the storage system's digital content. In one embodiment, the current store may be presented to the storage system as primary volumes. In another embodiment, the current store may be presented as secondary volumes which are referred to as “TimeSafe volumes.” The time store may record information associated with each intercepted write command, such as new data in the write command's payload or old data to be overwritten in response to the write command. Recordation of the new or old data in response to a write command may be referred to as a copy-on-write (COW) operation, and the new and/or old data recorded may be referred to as COW data. The time store may also record other information (i.e., metadata) associated with an intercepted write command and/or the corresponding COW operation, such as, for example, a timestamp, an original location in the current store (or TimeSafe volumes) where the old data are overwritten, and a destination location in the time store to which the COW data are copied.
FIG. 1 shows a system diagram illustrating an exemplary time-dependent storage management system 10 in relation to a storage system 12 and hosts/servers 102. The storage system 12 presents primary volumes 104 to the hosts/servers 102, and a current store 108 in the storage management system 10 presents TimeSafe volumes (secondary volumes) 106 to the hosts/servers 102. When the primary volumes 104 receive input/output (I/O) requests from the hosts/servers 102, the write requests may be simultaneously forwarded to or intercepted by the storage management system 10. COW operations may cause backup data to be recorded in a time store 110 in the storage management system 10, and a mirror/current copy of the digital content of the storage system 12 may be maintained in the current store 108.
Each COW operation typically backs up one or more blocks of COW data, thereby creating one set of COW data and corresponding metadata. Over a period of time, multiple sets of COW data and corresponding metadata (including timestamps) may be accumulated as a collection of historical records of what have been written or overwritten in the current store or the storage system. The content of the time store may be indexed (e.g., in “indexing tables”) based on the metadata to facilitate efficient access to the COW data.
With a current copy of the storage system's digital content in the current store and the historical records in the time store, the storage management system adds a new dimension, i.e., time, to the storage system. Assuming the storage management system has been operatively coupled to the storage system since a past time, the storage management system may quickly and accurately restore any addressable content in the storage system to any point in time between the past time and a present time. For example, the storage management system may be capable of providing a snapshot of the digital content of the storage system (or a portion thereof) that existed at a specified past time T1. The snapshot at time T1 may be presented in the form of a virtual disk known as a “time image.” The storage management system may also be capable of instantly restoring the storage system (or a portion thereof) to a state as it existed at a specified past time T2, which operation is referred to as an “instant restore.” The instant restore may be either non-destructive or destructive depending on whether the data overwritten during the restoration are recorded in the time store or discarded. A time image or a TimeSafe LUN (logical unit) in an instant restore mode may continue to receive I/O requests, such as reads and writes. Such I/O requests may be referred to as “time image reads” and “time image writes” if directed to a time image, or “instant restore reads” and “instant restore writes” if directed to a TimeSafe LUN in an instant restore mode.
In a storage system protected by the storage management system as briefly described above, it is often desirable for a user to query historical data such as those that existed at a specified address (or address range) at a specified past time. By generating a time image or performing an instant restore based on the specified address and time, such historical data may be accessed by the user. However, it is inefficient for the storage management system to generate a time image or to perform an instant restore every time I/O requests for some historical data are received. There exists a need for a general-purpose query engine that can efficiently respond to I/O requests for historical data.
In view of the foregoing, it would be desirable to provide a solution for data storage management which overcomes the above-described inadequacies and shortcomings.